.code-editor {
  overflow: auto;
  height: 100%;
  font-size: var(--requestly-font-size-sm, 12px);

  .cm-editor {
    height: 100%;
    background: var(--requestly-color-background);

    .cm-line {
      padding-top: 4px;
    }
  }

  .cm-gutters {
    background: transparent;
  }

  .cm-gutter.cm-lineNumbers {
    width: 20px;

    .cm-gutterElement {
      text-align: left;
      font-weight: 500;
      padding-top: 2px;
    }
  }

  .cm-gutter.cm-foldGutter {
    padding-top: 2px;
  }
}

.custom-handle {
  height: 25px;
  background: var(--requestly-color-surface-0);
  background-image: url();
  background-repeat: no-repeat;
  background-position: 50%;
  transition: 0.3s all;
  cursor: row-resize;
  border-radius: 0 0 4px 4px;
  border: 1px solid var(--requestly-color-white-t-10);
}

.code-editor-character-count {
  text-align: right;
  margin-right: 8px;
  margin-top: 2px;
  color: var(--requestly-color-text-subtle);
  font-size: var(--requestly-font-size-xs);
}

.code-editor-fullscreen-modal {
  .ant-modal {
    width: 100% !important;
    max-width: 1440px;
    top: 0px;
    padding: 8px;
    margin: 0 auto;

    .ant-modal-content {
      border-radius: var(--space-4, 8px);
      border: 1px solid var(--requestly-color-white-t-10, rgba(255, 255, 255, 0.06));

      .ant-modal-body {
        padding: 8px 8px 24px 8px !important;
        height: calc(100vh - 54px) !important; // 54px -> vertical padding + footer height

        .code-editor {
          border: none;
          border-radius: 4px;
          height: calc(100% - 20px);
          background: var(--requestly-color-surface-0, #212121);
        }
      }

      .ant-modal-footer {
        padding: 8px;
        border: none;
      }
    }
  }
}
